home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus Special 19
/
AMIGAplus Sonderheft 19 (1999)(ICP)(DE)[!].iso
/
Demoversionen
/
Anwendungen
/
gendemo104
/
Install
< prev
next >
Wrap
Text File
|
1999-02-21
|
12KB
|
380 lines
; $VER: Genesis Installer v1.2 (archive) (08-Feb99)
;
; Copyright © 1998-99 Active Technologies
; http://www.active-net.co.uk
;
; Install script by Michael Neuweiler <dolphin@unizh.ch>
;
; Piracy and unlawful duplication of this package may result in
; criminal prosecution to the full extent of UK and European law.
(complete 0)
(set @app-name "Genesis")
(set #error-msg "An unexpected error has occured. Installation aborted.")
(message "\n"
"Welcome to the " @app-name " installer.\n"
"\n"
"\n"
"© Active Technologies 1998-99\n"
"\n"
"http://www.active-net.co.uk\n"
"\n"
"\n"
"\n"
"Piracy and unlawful duplication of this package may result in "
"criminal prosecution to the full extent of UK and European law."
)
; Main component names & def pattern
(set #Genesis-name "Genesis v1.0.4")
(set #sana2-name "Sana II Network drivers")
(set #mcc-name "MUI Custom Classes")
(set #cats-name "Genesis Catalogs")
(set #install-choice %1011)
; main Genesis dirs
(set #source-dir "")
(set #libs-dir (tackon #source-dir "Libs"))
(set #reg-dir (tackon #source-dir "Register"))
(set #devs-net-dir (tackon #source-dir "Devs/Networks"))
(set #mcc-dir (tackon #source-dir "MUI/Libs/MUI"))
(set #catalog-dir (tackon #source-dir "Catalogs"))
(set #Genesis-dir "Genesis")
; AmiTCP dirs/assigns
(set #amitcp-name "AmiTCP")
(set #amitcp-assign "AmiTCP:")
(set #db-dir (tackon #amitcp-assign "db"))
(set #bin-dir (tackon #amitcp-assign "bin"))
(welcome)
(onerror
(if old-atcp-directory
(makeassign #atcp-dir #old-amitcp-dir))
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure check-system-version
(transcript "checking system version")
(if (< (/ (getversion) 65536) 37)
(exit "\n\n" @app-name " requires Kickstart version 2.1 or above.\n\n\n"
"Installation aborted.\n\n"
(quiet)
)
)
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure check-old-assign
(transcript "Checking for already installed AmiTCP.")
(set #old-amitcp-dir
(if (exists #amitcp-assign (noreq))
(getassign #amitcp-name)
"")
)
(if #old-amitcp-dir
(transcript "Existing AmiTCP detected at directory " #old-amitcp-dir "."))
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure check-cpu-type
(transcript "checking CPU type")
(set #cpu-type (database "cpu"))
(if (= #cpu-type "68060")
(set #cpu-choice 4)
(if (= #cpu-type "68040")
(set #cpu-choice 3)
(if (= #cpu-type "68030")
(set #cpu-choice 2)
(if (= #cpu-type "68020")
(set #cpu-choice 1)
(set #cpu-choice 0)
)
)
)
)
(set #cpu-choice
(askchoice
(choices "68000" "68020" "68030" "68040" "68060")
(prompt "Please select which CPU " @app-name " will be running on.")
(help "Some parts of the " @app-name " package have been optimised for specific members of the 68000 processor family. "
"You should select the processor that " @app-name " will be running on so that the most appropriate programs will be used.")
(default #cpu-choice)
)
)
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure ask-install
(set #install-choice
(askoptions
(prompt "Please select which parts of the " @app-name " package you wish to install.")
(help "There are several parts to the " @app-name " package, some of which you may or may not wish to install. "
"Many of the parts are unique to this release, so if you have not installed any of these already you should select them all.")
(choices (cat #Genesis-name " (TCP/IP stack)")
(cat #sana2-name " (required for ppp, slip)")
(cat #cats-name " (Genesis catalog files)")
(cat #mcc-name " (required)")
)
(default #install-choice)
)
)
(if (= 0 #install-choice)
(exit "\n\n\n\nNo " @app-name " components have been selected.\n"
"Installation aborted.\n" (quiet))
)
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure ask-dst-dir
(if (exists "Internet:" (noreq))
(set @default-dest "Internet:")
(if (exists "Work:" (noreq))
(set @default-dest "Work:")
(set @default-dest "SYS:")
)
)
(set @default-dest
(askdir
(prompt "Please select where you would like " @app-name " installed. "
"A drawer called '" #Genesis-dir "' will be created there.")
(help "Select where you would like " @app-name " installed."
"The installer will then create a drawer called '" #Genesis-dir "', "
"and copy the programs and documentation into it.")
(default @default-dest)
(newpath)
)
)
(if (NOT (= 2 (exists (tackon @default-dest #Genesis-dir))))
(makedir (tackon @default-dest #Genesis-dir)))
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; arguments:
;;
;; uus::commands - commands to add
;; uus::section - section name
;;
(procedure update-user-startup
(set uus::complete (cat ";BEGIN " uus::section "\n"
uus::commands
";END " uus::section "\n"))
(set startup-changed 1)
(startup
uus::section
(command uus::commands)
(prompt "Installer will modify your S:User-Startup file. "
"Following lines will be appended to it:\n\n"
uus::complete)
(help " Installer needs to make indicated modifications to your user startup file.\n"
" You should make modifications later by hand if you skip this part.")
)
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure install-mcc
(working "Checking MUI custom classes...")
(if (= 2 (exists "MUI:Libs/MUI/" (noreq)))
(
(transcript "found existing MUI:libs/MUI dir")
(foreach "MUI/Libs/MUI" "#?"
(
(copylib
(prompt "Installing " @each-name)
(confirm)
(help @copylib-help)
(source (tackon "MUI/Libs/MUI" @each-name))
(dest "MUI:libs/mui/")
(optional "askuser" "force")
)
))
))
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure install-catalogs
(copyfiles
(prompt "Installing catalogs")
(help @copyfiles-help)
(source #catalog-dir)
(dest "LOCALE:Catalogs")
(choices "Deutsch" "Italiano")
(confirm)
)
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure install-reg
(copyfiles
(source #source-dir)
(dest @default-dest)
(choices #reg-dir (cat #reg-dir ".info"))
(infos)
)
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure install-devs
(transcript "installing SanaII drivers")
(if (NOT (exists "DEVS:Networks"))
(makedir "DEVS:Networks")
)
(if (= 0 #cpu-choice) (set #appp-name "appp.device"))
(if (= 1 #cpu-choice) (set #appp-name "appp.device.020"))
(if (= 2 #cpu-choice) (set #appp-name "appp.device.030"))
(if (= 3 #cpu-choice) (set #appp-name "appp.device.030"))
(if (= 4 #cpu-choice) (set #appp-name "appp.device.030"))
(copylib (prompt "Updating appp.device.")
(help @copylib-help)
(confirm)
(source (tackon "Devs/Networks" #appp-name))
(dest "Devs:networks/")
(newname "appp.device")
(optional "askuser" "force")
)
(copylib
(prompt "Copying aslip.device to:\n\nDEVS:Networks")
(help @copylib-help)
(source (tackon "Devs/Networks" "aslip.device"))
(dest "DEVS:Networks")
(optional "force")
(confirm)
)
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(procedure install-Genesis
(copyfiles
(prompt "Copy the Genesis icon")
(help @copyfiles-help)
(source #source-dir)
(choices "Genesis.info")
(dest @default-dest)
(optional "nofail")
)
(makeassign #amitcp-name (expandpath (tackon @default-dest #Genesis-dir)))
(if (NOT (= 2 (exists (tackon #amitcp-assign "devs"))))
(makedir (tackon #amitcp-assign "devs")))
(copyfiles
(prompt "Copying Genesis files to:\n\n" @default-dest)
(help @copyfiles-help)
(source (tackon #source-dir #Genesis-dir))
(dest (tackon @default-dest #Genesis-dir))
(all)
(infos)
(optional "nofail"))
(copyfiles
(prompt "Copying Genesis docs to:\n\n" (tackon @default-dest #Genesis-dir))
(help @copyfiles-help)
(source (tackon (tackon #source-dir #Genesis-dir) "Docs"))
(dest (tackon (tackon @default-dest #Genesis-dir) "Docs"))
(all)
(infos)
(optional "nofail"))
(if (NOT (= 2 (exists (tackon #amitcp-assign "log"))))
(makedir (tackon #amitcp-assign "log")))
(if (NOT (= 1 (exists (tackon #amitcp-assign "log/wtmp"))))
(textfile (dest (tackon #amitcp-assign "log/wtmp"))))
(protect (tackon #bin-dir "netstat") "+s +e")
(protect (tackon #bin-dir "SynClock") "+s +e")
(protect (tackon #bin-dir "startnet") "+s +e")
(protect (tackon #bin-dir "stopnet") "+s +e")
(set uus::commands (cat "Assign " #amitcp-assign " \"" (expandpath (tackon @default-dest #Genesis-dir)) "\"\n"
"path " (tackon #amitcp-assign "bin") " add\n"
"Assign APIPE: Exists > NIL:\n"
"IF Warn\n"
" Mount APIPE: from " (tackon #amitcp-assign "devs/APipe-Mountlist") "\n"
"EndIf\n"))
(set uus::section "AmiTCP/IP")
(update-user-startup)
(foreach #libs-dir "#?"
(copylib
(prompt "Copying " @each-name " to:\n\n" "LIBS:")
(help "You should copy all libraries if you want Genesis to work correctly.")
(source (tackon #libs-dir @each-name))
(dest "LIBS:")
(optional "askuser" "force")
(confirm)
)
)
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;
;;; Installatation sequence
;;;
(complete 00) (transcript "On making " app-name ".")
(complete 02) (check-system-version)
(complete 04) (check-old-assign)
(complete 06) (check-cpu-type)
(complete 10) (ask-install)
(complete 15) (ask-dst-dir)
(complete 30) (if (IN #install-choice 00) (install-Genesis))
(complete 50) (if (IN #install-choice 01) (install-devs))
(complete 60) (if (IN #install-choice 02) (install-catalogs))
(complete 70) (if (IN #install-choice 03) (install-mcc))
(complete 80) (if (IN #install-choice 00) (install-reg))
(complete 90)
(if (IN #install-choice 00)
(
(if (= 1 (askbool
(prompt "\nWould you like to launch Genesis Wizard to configure the just installed Genesis ?\n")
(help "The Genesis Wizard will help you to configure Genesis for the first time with"
"little effort. We advise you to use the Wizard if you are unfamiliar with setting up a network.")
(default 1)))
(
(run "run AmiTCP:GenesisWizard")
))
))
(complete 100)
;; EOF
;;